package com.zmn.plat.model.entity.part;

import com.zmn.common.dictionary.GlobalDict;
import com.zmn.common.utils.pager.Operator;

import java.util.Date;
import java.util.Objects;


/**
 * 类描述 配件实体
 *
 * @author DaiZhichao
 * @since 2018/10/26 10:50
 */

public class PartSku extends Operator {

    private Integer skuId;

    /**
     * 公司ID(一级单位)
     */
    private Integer companyId;

    /**
     * 配件名称
     */
    private String name;

    /**
     * 厂家配件名称
     */
    private String factoryName;

    /**
     * 冗余拼音: 配件拼音
     */
    private String pinyin;

    /**
     * 冗余名称: 配件大类名称 + 配件小类名称 + 配件名称
     */
    //@Field(type = FieldType.Text, searchAnalyzer = "pinyin", analyzer = "pinyin")
    private String fullName;


    /**
     * 配件1类型Id
     */
    private Integer categOneId;

    /**
     * 配件2类型Id
     */
    private Integer categId;

    /**
     * 配件图片
     */
    private String imgSrc;

    /**
     * 配件图片
     */
    private String imgSrc2;

    /**
     * 配件图片
     */
    private String imgSrc3;

    /**
     * 配件图片
     */
    private String imgSrc4;

    /**
     * 配件品牌ID：如果0表示无品牌
     */
    private Integer brandId;

    /**
     * 单位
     */
    private String unit;

    /**
     * 包装规格
     */
    private String packSpec;

    /**
     * 排序号，编号越小越靠前
     */
    private Integer sort;

    /**
     * 状态：1停用，2启用
     */
    private Short status;

    /**
     * 创建人
     */
    private String creater;

    /**
     * 更新人
     */
    private String updater;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 更新时间
     */
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public Integer getSkuId() {
        return skuId;
    }

    public void setSkuId(Integer skuId) {
        this.skuId = skuId;
    }

    public Integer getCompanyId() {
        return companyId;
    }

    public void setCompanyId(Integer companyId) {
        this.companyId = companyId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getFactoryName() {
        return factoryName;
    }

    public void setFactoryName(String factoryName) {
        this.factoryName = factoryName;
    }

    public String getPinyin() {
        return pinyin;
    }

    public void setPinyin(String pinyin) {
        this.pinyin = pinyin;
    }

    public String getFullName() {
        return fullName;
    }

    public void setFullName(String fullName) {
        this.fullName = fullName;
    }

    public Integer getCategOneId() {
        return categOneId;
    }

    public void setCategOneId(Integer categOneId) {
        this.categOneId = categOneId;
    }

    public Integer getCategId() {
        return categId;
    }

    public void setCategId(Integer categId) {
        this.categId = categId;
    }

    public String getImgSrc() {
        return imgSrc;
    }

    public void setImgSrc(String imgSrc) {
        this.imgSrc = imgSrc;
    }

    public String getImgSrc2() {
        return imgSrc2;
    }

    public void setImgSrc2(String imgSrc2) {
        this.imgSrc2 = imgSrc2;
    }

    public String getImgSrc3() {
        return imgSrc3;
    }

    public void setImgSrc3(String imgSrc3) {
        this.imgSrc3 = imgSrc3;
    }

    public String getImgSrc4() {
        return imgSrc4;
    }

    public void setImgSrc4(String imgSrc4) {
        this.imgSrc4 = imgSrc4;
    }

    public Integer getBrandId() {
        return brandId;
    }

    public void setBrandId(Integer brandId) {
        this.brandId = brandId;
    }

    public String getUnit() {
        return unit;
    }

    public void setUnit(String unit) {
        this.unit = unit;
    }

    public String getPackSpec() {
        return packSpec;
    }

    public void setPackSpec(String packSpec) {
        this.packSpec = packSpec;
    }

    public Integer getSort() {
        return sort;
    }

    public void setSort(Integer sort) {
        this.sort = sort;
    }

    public Short getStatus() {
        return status;
    }

    public void setStatus(Short status) {
        this.status = status;
    }

    public String getCreater() {
        return creater;
    }

    public void setCreater(String creater) {
        this.creater = creater;
    }

    public String getUpdater() {
        return updater;
    }

    public void setUpdater(String updater) {
        this.updater = updater;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Boolean getStatusBoolean() {
        return Objects.equals(this.status, GlobalDict.STATUS_ENABLE);
    }
}